<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<HTML><HEAD><TITLE>云和租房 - 用户登录</TITLE>
    <META content="text/html; charset=utf-8" http-equiv=Content-Type><LINK
            rel=stylesheet type=text/css href="../css/style.css">
    <META name=GENERATOR content="MSHTML 8.00.7601.17514"></HEAD>
<BODY>
<link rel="stylesheet" type="text/css" href="css/verify.css">
<script src="js/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript" src="js/verify.js" ></script>

<DIV id=header class=wrap>
    <DIV id=logo><IMG src="../images/logo.gif"></DIV></DIV>
<DIV id=regLogin class=wrap>
    <DIV class=dialog>
        <DIV class=box>
            <H4>用户登录</H4>
            <div><font color="red">${msg}</font> </div>
            <FORM id=user method=post action="user_login.action" onsubmit="return flag">
                <DIV class=infos>
                    <TABLE class=field>
                        <TBODY>
                        <TR>
                            <TD colSpan=2></TD></TR>
                        <TR>
                            <TD class=field>用 户 名：</TD>
                            <TD><INPUT  id=user_name class=text type=text name=name required> </TD></TR>
                        <TR>
                            <TD class=field>密　　码：</TD>
                            <TD><INPUT id=user_password class=text type=password name=password required> </TD></TR>
						<tr>
                            <td colspan="2"><div id="mpanel4" style="margin-top:50px;">
                            </div></td>
                        </tr>
						</TBODY></TABLE>
                    <DIV class=buttons> <INPUT  value=登陆 type="submit"> <INPUT onclick='document.location="reg.jsp"' value=注册 type=button>
                        <input type="password" id="times" name="loginTimes" value="${loginTimes}" hidden>
                    </DIV></DIV></FORM></DIV></DIV></DIV>
<DIV id=footer class=wrap>
    <DL>
        <DT>云和租房 © 2010 云和 京ICP证1000001号</DT>
        <DD>关于我们 · 联系方式 · 意见反馈 · 帮助中心</DD></DL></DIV></BODY></HTML>

<script type="text/javascript">
    var flag = true;


    $(function () {

        if ($("#times").val()>=3){
            check();
            flag = false;
        }
    })

function check(){
    $('#mpanel4').slideVerify({
        type : 2,		//类型
        vOffset : 5,	//误差量，根据需求自行调整
        vSpace : 5,	//间隔
        imgName : ['1.jpg', '2.jpg'],
        imgSize : {
            width: '400px',
            height: '200px',
        },
        blockSize : {
            width: '40px',
            height: '40px',
        },
        barSize : {
            width : '400px',
            height : '40px',
        },
        ready : function() {
        },
        success : function() {
            flag = true;
        },
        error : function() {
//		        	alert('验证失败！');
            flag = false;
        }

    });
}

</script>